Eilenberg-Moore Monoids and Backtracking Monad Transformers

نویسنده

  • Maciej Piróg
چکیده

We develop an algebraic underpinning of backtracking monad transformers in the general setting of monoidal categories. As our main technical device, we introduce Eilenberg–Moore monoids, which combine monoids with algebras for strong monads. We show that Eilenberg–Moore monoids coincide with algebras for the list monad transformer (‘done right’) known from Haskell libraries. From this, we obtain a number of results, including the facts that the list monad transformer is indeed a monad, a transformer, and an instance of the MonadPlus class. Finally, we construct an Eilenberg–Moore monoid of endomorphisms, which, via the codensity monad construction, yields a continuation-based implementation à la Hinze.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Order-adjoint monads and injective objects

Given a monad T on Set whose functor factors through the category of ordered sets with left adjoint maps, the category of Kleisli monoids is defined as the category of monoids in the hom-sets of the Kleisli category of T. The Eilenberg-Moore category of T is shown to be strictly monadic over the category of Kleisli monoids. If the Kleisli category of T moreover forms an order-enriched category,...

متن کامل

Applications of the Kleisli and Eilenberg-Moore 2-adjunctions

In 2010, J. Climent Vidal and J. Soliveres Tur developed, among other things, a pair of 2-adjunctions between the 2-category of adjunctions and the 2-category of monads. One is related to the Kleisli adjunction and the other to the Eilenberg-Moore adjunction for a given monad.Since any 2-adjunction induces certain natural isomorphisms of categories, these can be used to classify bijection...

متن کامل

Generic Weakest Precondition Semantics from Monads Enriched with Order

We devise a generic framework where a weakest precondition semantics, in the form of indexed posets, is derived from a monad whose Kleisli category is enriched by posets. It is inspired by Jacobs’ recent identification of a categorical structure that is common in various predicate transformers, but adds generality in the following aspects: 1) different notions of modality (such as “may” vs. “mu...

متن کامل

On the monadic nature of categories of ordered sets

If S is an order-adjoint monad, that is, a monad on Set that factors through the category of ordered sets with left adjoint maps, then any monad morphism τ : S → T makes T orderadjoint, and the Eilenberg-Moore category of T is monadic over the category of monoids in the Kleisli category of S.

متن کامل

Exponential Kleisli Monoids as Eilenberg-Moore Algebras

Lax monoidal powerset-enriched monads yield a monoidal structure on the category of monoids in the Kleisli category of a monad. Exponentiable objects in this category are identified as those Kleisli monoids with algebraic structure. This result generalizes the classical identification of exponentiable topological spaces as those whose lattice of open subsets forms a continuous lattice.

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2016